Test Run Script

The test run script describes the MATLAB commands for the test execution of a single test case. This script is set default, generated automatically on platform creation. You can change it afterwards, in order to adapt it to your needs.

Test run script

Code coverage

Reporting only

Sets the coverage criteria in the trial script.

If checked: TPT does not start the coverage tool itself. You need to activate and do the setup manually. Moreover, you can make other additional settings. For the report, TPT will use the coverage data only.

Depending on the tool, add the following different commands to the script to configure the code coverage. It is necessary to configure the code coverage before the simulation starts. Therefore add the following commands above the sim() command in the trial script.

The settings for the coverage tool need to match the settings in TPT.

Enable

Click Enable to select a coverage tool from the drop-down list.

TargetLink

A TargetLink model and TargetLink software are needed.

If Reporting only is not checked, TPT will export the coverage for each test into a separate file within the testdata folder. In the end, this data is reimported into the data dictionary to build the coverage report. This prevents the loss of coverage data even if the SIL is rebuilt for each test case via the test run script.

CTC++ for TargetLink

A TargetLink model, TargetLink and CTC++ software are needed. For more information, see Code Coverage - CTC++.

Note that by rebuilding the SIL via the test run script, coverage data of previous test cases might be lost as it may be deleted by TargetLink.

Simulink V&V / Simulink Coverage

A Simulink model and the "Simulink Simulink Verification and Validation toolbox" / "Simulink Coverage" toolbox is needed.

Rename coverage variable

This button becomes only active when you select Simulink V&V tool for code coverage. It opens the Edit Coverage Variable Names dialog where you can rename the MATLAB coverage variables.

Edit Coverage Variable Names